#MAKE FILE FOR HSAProfileAgent
PROJECT_NAME=HSAProfileAgent
DEPTH = ../..
include $(DEPTH)/Build/Linux/Common.mk

TARGETSO = $(OUTPUT_BIN_DIR)/lib$(GPU_PROFILER_LIB_PREFIX)$(PROJECT_NAME)$(TARGET_SUFFIX).so

ADDL_DEFINES = -DAMD_INTERNAL_BUILD
ADDL_CFLAGS = $(HSAFDN_CFLAGS)

INCLUDES = \
	-I. \
	-isystem$(GPU_PERF_API_DIR) \
	-isystem$(CAL_DIR)/include \
	-I$(COMMON_PROJ_DIR) \
	-I$(SRC_COMMON_DIR) \
	-I$(SRC_HSAFDNCOMMON_DIR) \
	-I$(HSA_DIR)/include \
	-I$(HSA_DIR)/include/hsa \
	-I$(HSA_DIR)/../include \
	-I$(HSA_DIR)/../include/rocprofiler \
	-I$(DYNAMICLIBRARYMODULE_DIR) \
	-I$(COMGR_DIR) \
	-I$(HSA_DIR)/../include/comgr \
	-I$(COMGRUTILS_DIR) \
	-I$(DEVICEINFO_DIR) \
	-I$(TSINGLETON_DIR) \
	-I$(ADL_DIR)/include

LIBS = \
	$(HSAFDNCOMMON_LIBS) \
	$(COMMON_LIBS) \
	$(FRAMEWORK_LIBS) \
	$(STANDARD_LIBS) \

LIBPATH = $(COMMON_LIB_PATHS)

SO_OBJS = \
	./$(OBJ_DIR)/HSAPMCAgent.o \
	./$(OBJ_DIR)/HSAPMCInterceptionHelpers.o \
	./$(OBJ_DIR)/HSAGPAProfiler.o \
	./$(OBJ_DIR)/HSAPMCInterception.o \
	./$(OBJ_DIR)/CLCUInfoBase.o \
	./$(OBJ_DIR)/CLOccupancyFile.o \
	./$(OBJ_DIR)/CLOccupancyInfoManager.o \
	./$(OBJ_DIR)/ProfilerTimer.o \
	./$(OBJ_DIR)/ADLUtil.o \
	./$(OBJ_DIR)/ComgrUtils.o \
	./$(OBJ_DIR)/HSAKernelAssembly.o \

include $(DEPTH)/Build/Linux/CommonTargets.mk

$(OBJ_DIR)/%.o: AutoGenerated/%.cpp
	$(BUILD_SRC)

#the following are temporary until I move the Occupancy files into a shared location
$(OBJ_DIR)/%.o: ../CLCommon/%.cpp
	$(BUILD_SRC)

# END OF MAKE FILE
